<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:ui="http://xmlns.jcp.org/jsf/facelets"
      xmlns:h="http://xmlns.jcp.org/jsf/html"
      xmlns:f="http://xmlns.jcp.org/jsf/core">

    <ui:composition template="/template.xhtml">
        <ui:define name="title">
            <h:outputText value="#{bundle.CreateUserTitle}"></h:outputText>
        </ui:define>
        <ui:define name="body">
            <h:panelGroup id="messagePanel" layout="block">
                <h:messages errorStyle="color: red" infoStyle="color: green" layout="table"/>
            </h:panelGroup>
            <h:form>
                <h:panelGrid columns="2">
                    <h:outputLabel value="#{bundle.CreateUserLabel_userEmail}" for="userEmail" />
                    <h:inputText id="userEmail" value="#{userController.selected.userEmail}" title="#{bundle.CreateUserTitle_userEmail}" required="true" requiredMessage="#{bundle.CreateUserRequiredMessage_userEmail}"/>
                    <h:outputLabel value="#{bundle.CreateUserLabel_userPassword}" for="userPassword" />
                    <h:inputText id="userPassword" value="#{userController.selected.userPassword}" title="#{bundle.CreateUserTitle_userPassword}" required="true" requiredMessage="#{bundle.CreateUserRequiredMessage_userPassword}"/>
                    <h:outputLabel value="#{bundle.CreateUserLabel_userFirstName}" for="userFirstName" />
                    <h:inputText id="userFirstName" value="#{userController.selected.userFirstName}" title="#{bundle.CreateUserTitle_userFirstName}" />
                    <h:outputLabel value="#{bundle.CreateUserLabel_userLastName}" for="userLastName" />
                    <h:inputText id="userLastName" value="#{userController.selected.userLastName}" title="#{bundle.CreateUserTitle_userLastName}" />
                    <h:outputLabel value="#{bundle.CreateUserLabel_userJobTitile}" for="userJobTitile" />
                    <h:inputText id="userJobTitile" value="#{userController.selected.userJobTitile}" title="#{bundle.CreateUserTitle_userJobTitile}" />
                    <h:outputLabel value="#{bundle.CreateUserLabel_userCalendar}" for="userCalendar" />
                    <h:inputText id="userCalendar" value="#{userController.selected.userCalendar}" title="#{bundle.CreateUserTitle_userCalendar}" />
                    <h:outputLabel value="#{bundle.CreateUserLabel_userSuspended}" for="userSuspended" />
                    <h:inputText id="userSuspended" value="#{userController.selected.userSuspended}" title="#{bundle.CreateUserTitle_userSuspended}" />
                </h:panelGrid>
                <br />
                <h:commandLink action="#{userController.create}" value="#{bundle.CreateUserSaveLink}" />
                <br />
                <br />
                <h:commandLink action="#{userController.prepareList}" value="#{bundle.CreateUserShowAllLink}" immediate="true"/>
                <br />
                <br />
                <h:link outcome="/index" value="#{bundle.CreateUserIndexLink}"/>
            </h:form>
        </ui:define>
    </ui:composition>

</html>
